home *** CD-ROM | disk | FTP | other *** search
-
- Public Class TraceForm
- Inherits System.Web.UI.Page
- Protected WithEvents txtValue As System.Web.UI.WebControls.TextBox
- Protected WithEvents btnRefresh As System.Web.UI.WebControls.Button
- Protected WithEvents lblTime As System.Web.UI.WebControls.Label
-
- #Region " Web Form Designer Generated Code "
-
- 'This call is required by the Web Form Designer.
- <System.Diagnostics.DebuggerStepThrough()> Private Sub InitializeComponent()
-
- End Sub
-
- Private Sub Page_Init(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Init
- 'CODEGEN: This method call is required by the Web Form Designer
- 'Do not modify it using the code editor.
- InitializeComponent()
- End Sub
-
- #End Region
-
- Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
- Trace.TraceMode = TraceMode.SortByTime
- DoSomething("ABC")
- End Sub
-
- ' a sample routine that outputs to the Trace page
-
- Sub DoSomething(ByVal arg As String)
- Trace.Write("FLOW", "Entering Sub DoSomething")
- Trace.Write("arg = " & arg)
-
- Try
- Throw New ArgumentException()
- Catch ex As Exception
- Trace.Warn("ERRORS", "An exception has occurred", ex)
- Finally
- Trace.Write("FLOW", "Exiting Sub DoSomething")
- End Try
- End Sub
-
- End Class
-